package com.aurora.spider.houyuantuan;

import com.geccocrawler.gecco.annotation.*;
import com.geccocrawler.gecco.request.HttpRequest;
import com.geccocrawler.gecco.spider.HrefBean;
import com.geccocrawler.gecco.spider.HtmlBean;

import java.util.List;

/**
 * Created by jackie on 18/1/15.
 */
@Gecco(matchUrl="https://www.houyuantuan.com/search/mingxing/?search={userName}", pipelines={"consolePipeline","searchDealLine"})
public class Search implements HtmlBean {

    @Request
    private HttpRequest request;

    @RequestParameter
    private String userName;

    // 查询的多个结果
    @HtmlField(cssPath  = "body > div.wrapper > div.container > div > div > ul > li > div.info > div > a")
    private List<HrefBean> newList;

    public HttpRequest getRequest() {
        return request;
    }

    public void setRequest(HttpRequest request) {
        this.request = request;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public List<HrefBean> getNewList() {
        return newList;
    }

    public void setNewList(List<HrefBean> newList) {
        this.newList = newList;
    }
}
